Assessment of lung mechanics and heart-lung interactions